export const BASE_URL = process.env.VUE_APP_BASE_API;
export const IMAGE_OSS_URL = "http://shoeswasher.oss-cn-heyuan.aliyuncs.com/";
export const washTypeList = [
  { label: "普洗", value: "普洗" },
  { label: "精洗", value: "精洗" },
  { label: "奢洗", value: "奢洗" },
  { label: "干洗", value: "干洗" },
];
export const shoeStatusMap = { 0: "待清洗", 1: "清洗中", 2: "清洗完成" };
export const shoeStatusList = Object.keys(shoeStatusMap).map((key) => {
  return { value: key, label: shoeStatusMap[key] };
});
export const orderComeFromMap = {
  1: "到店",
  2: "美团",
  3: "抖音",
  4: "小程序",
};
export const orderComeFromList = Object.keys(orderComeFromMap).map((key) => {
  return { value: key, label: orderComeFromMap[key] };
});
export const orderStatusMap = {
  "-1": "待支付",
  0: "已取消",
  1: "取鞋中",
  2: "待入库",
  3: "清洗中",
  4: "待出库",
  5: "送鞋中",
  6: "已完成",
  7: "待质检"
};
export const orderStatusList = Object.keys(orderStatusMap).map((key) => {
  return { value: key, label: orderStatusMap[key] };
});
export const settlementStatusMap = { 2: "已核销" };
export const settlementStatusList = Object.keys(settlementStatusMap).map(
  (key) => {
    return { value: key, label: settlementStatusMap[key] };
  }
);
export const logisticsCompany = { 1: "京东" };
export const logisticsCompanyList = Object.keys(logisticsCompany).map((key) => {
  return { value: key, label: logisticsCompany[key] };
});

// 物流状态
export const logisticsStatusMap = {
  100: "已接单",
  390: "已下发",
  403: "控单中",
  420: "已揽收",
  430: "运输中",
  440: "派送中",
  480: "已拦截",
  500: "异常终止",
  510: "妥投",
  530: "拒收",
  690: "已取消",
};
export const logisticsStatusList = Object.keys(logisticsStatusMap).map(
  (key) => {
    return { value: key, label: logisticsStatusMap[key] };
  }
);

// 店铺状态
export const shopStatusMap = { 1: "上架", 2: "下架" };
export const shopStatusList = Object.keys(shopStatusMap).map((key) => {
  return { value: key, label: shopStatusMap[key] };
});
// 预约时间区间，精确到小时, 8点到晚上8点
export const appointmentTimeList = [
  { label: "08:00 - 09:00", startTime: 8, endTime: 9 },
  { label: "09:00 - 10:00", startTime: 9, endTime: 10 },
  { label: "10:00 - 11:00", startTime: 10, endTime: 11 },
  { label: "11:00 - 12:00", startTime: 11, endTime: 12 },
  { label: "12:00 - 13:00", startTime: 12, endTime: 13 },
  { label: "13:00 - 14:00", startTime: 13, endTime: 14 },
  { label: "14:00 - 15:00", startTime: 14, endTime: 15 },
  { label: "15:00 - 16:00", startTime: 15, endTime: 16 },
  { label: "16:00 - 17:00", startTime: 16, endTime: 17 },
  { label: "17:00 - 18:00", startTime: 17, endTime: 18 },
  { label: "18:00 - 19:00", startTime: 18, endTime: 19 },
];
export const couponTypeMap = { 0: "新人卷", 1: "满减券", 2: "补偿赠券" };
export const couponTypeList = Object.keys(couponTypeMap).map((key) => {
  return { value: Number(key), label: couponTypeMap[key] };
});
export const productFormType = {
  // 1: "到店",
  2: "美团",
  3: "抖音",
  // 4: "小程序",
};


export const productFormTypeList = Object.keys(productFormType).map((key) => {
  return { value: key, label: productFormType[key] };
});

//与后端接口查询映射关系字典
export const productFormTypeListDic = {
  // 1: "DD",
  2: "MT",
  3: "DY",
  // 4: "XCX",
};



export const userCouponStatusMap = { 1: "已使用", 0: "未使用", "-1": "已过期" };
export const userCouponStatusList = Object.keys(userCouponStatusMap).map(
  (key) => ({ name: userCouponStatusMap[key], value: key })
);
export const mtOrderStatus = {
  ALLOCATED: "已分配",
  PICKED_UP: "已取件",
  ARRIVED: "已到达",
  CLEANING: "清洗中",
  RETURNING: "返回中",
  COMPLETION: "履约完成",
};
export const tikTokOrderStatus = {
  1: "已寄出",
  2: "洗护完成",
  3: "已寄回",
  4: "服务完成",
};
export const mtOrderStatusList = Object.keys(mtOrderStatus).map((key) => {
  return { value: key, label: mtOrderStatus[key] };
});
// 分销类型
export const regionDistributorTypeMap = { 1: "收入", 2: "支出" };
export const regionDistributorTypeList = Object.keys(
  regionDistributorTypeMap
).map((key) => {
  return { value: key, label: regionDistributorTypeMap[key] };
});
// 分销状态
export const regionDistributorStatusMap = { 0: "入账中", 1: "有效", 2: "无效" };
export const regionDistributorStatusList = Object.keys(
  regionDistributorStatusMap
).map((key) => {
  return { value: key, label: regionDistributorStatusMap[key] };
});
export const dyOrderStatus = {
  0: "成功",
  2100004: "系统繁忙，此时请开发者稍候再试",
  2100005: "参数不合法",
  2100007: "无权限操作",
  2190002: "access_token无效",
  2190004: "应用未获得该能力",
  2190008: "access_token过期,请刷新或重新授权",
  2191000: "内部错误",
  2191001: "风控类错误",
  2191002: "通用交易类错误",
  2191003: "正向交易类错误",
  2191004: "核销类错误",
  2191005: "逆向交易类错误",
  2191006: "资金类错误",
  2191007: "外部扩展相关错误",
  2191008: "营销优惠相关错误",
  2191009: "分账类错误",
  10000: "参数错误",
  13000: "内部服务错误",
  10002: "参数解析错误",
  11001: "访问未授权",
  11002: "AccessToken非法",
  11003: "Session非法",
  11004: "签名校验失败",
  11005: "用户未登录",
  11006: "商服关系未授权",
  12001: "访问过于频繁",
  12002: "用户账号异常",
  20000: "订单不存在",
  20001: "订单状态不正确",
  20002: "商品不存在",
  20003: "POI不存在",
  20004: "订单没有cps相关信息",
  20005: "查询订单信息失败",
  21000: "商品单与商户单不匹配",
  21001: "商品单状态不支持核销",
  21003: "该应用不在灰度白名单",
  21004: "营销算价结果信息不一致",
  21006: "未找到回调设置",
  21007: "无法查到商品关键信息",
  21012: "创建订单失败，请稍后重试",
  21013: "开发者拒绝交易",
  21015: "开发者返回的参数非法",
  21016: "外部单号已存在",
  21017: "外部单号格式不正确",
  21018: "非法的核销poi_id",
  21019: "商品价格有变动",
  21020: "商品不支持一次购买多份",
  21021: "用户购买超出限制",
  21022: "单次购买超出上限",
  21023: "商品已过期",
  21024: "商品已下线",
  21025: "商品已售罄",
  21026: "下单次数超限制",
  21030: "订单状态不支持关单",
  21032: "开发者商品id重复",
  21042: "商品状态无效",
  21043: "商品库存不足",
  21045: "订单已超时，无法继续支付",
  21046: "订单收款商户号不合法",
  21047: "商品单id不合法",
  21048: "下单失败，不允许非商品库商品下单",
  21110: "生成核销码失败",
  21111: "订单不运营推送核销状态，请使用抖音码（闭环核销）方案核销",
  21112: "此外部订单不是交易系统订单",
  21113: "三方码参数校验未通过",
  21114: "当前订单非抖音码订单，无法使用核销组件展示",
  21116: "预约商品不允许推送 核销状态",
  21117: "加价单不允许推送核销状态",
  22000: "订单不允许退款",
  22001: "订单item子单不允许退款",
  22002: "没有可以退款的item订单",
  22004: "外部退款单号重复了",
  22005: "因cps限制订单不允许退款",
  22006: "退款审核状态前置步骤未完成",
  22007: "超出单次最大可退款的商品数量",
  22008: "超出可退款的商品数量",
  22009: "发起退款的订单同时存在分账前和分账后状态",
  23001: "分账参数错误",
  23101: "订单不存在,无法分账",
  23102: "订单未支付,无法分账",
  23103: "小程序在禁止分账名单中,无法分账",
  23104: "服务商在禁止分账名单中,无法分账",
  23105: "支付后不满N天,无法分账",
  23106: "核销后不满N天,无法分账",
  23107: "订单未完成,无法分账",
  23108: "单笔订单分账次数过多",
  23109: "分账金额超过授权比例",
  23110: "服务商无对应小程序分账授权",
  23111: "out_settle_no已存在,请用查询接口查询分账结果",
  23112: "订单已无可分账金额",
  23113: "该订单不允许分账",
  23114: "消息版本号<已存在的版本号, 跳过本次更新",
  23115: "新poi未关联商户号",
  23116: "开发者未认领poi",
  23117: "该订单属于自动结算订单, 无需请求分账",
  23118: "不允许发起整单结算",
  23119: "不允许发起券结算",
  23120: "券未核销,无法分账",
  23121: "券结算功能灰度中，请联系客服或已对接的运营开通",
  24000: "扩展点服务配置不存在，请配置对应的扩展点",
  24001: "调用扩展点出错",
  25000: "活动信息无效",
  25001: "活动已结束",
  25002: "活动未开始",
  25003: "商品总价太低，无法使用优惠",
  25004: "当前商品无法使用优惠",
  25005: "用户不满足活动条件",
  26001: "当前订单状态不可支付",
  26002: "订单支付 token 无效",
  26003: "小程序违规，支付能力被封禁",
  26004: "商家账户升级中，请稍后",
};

export const wupingType = [
  {title:"衣服",choose:false }, 
  {title:"鞋子",choose:false }, 
  {title:"其它",choose:false }
]

export const peiShiType = [
  {title:"腰带",choose:false }, 
  {title:"毛领",choose:false }, 
  {title:"帽子",choose:false },
  {title:"袖带",choose:false }, 
  {title:"包装袋/盒",choose:false },
  {title:"遗留物",choose:false }, 
  {title:"其它",choose:false }
]

export const remarkType = [
  {title:"绒面鞋",choose:false }, 
  {title:"奢品",choose:false }, 
  {title:"皮衣",choose:false },
  {title:"皮毛一体",choose:false }, 
  {title:"四件套",choose:false },
  {title:"背包",choose:false }, 
  {title:" 脏尽洗",choose:false },
  {title:"油渍",choose:false },
  {title:"发霉",choose:false }, 
  {title:"血渍",choose:false },
  {title:"起毛",choose:false },
  {title:"破损",choose:false }, 
  {title:" 染色",choose:false },
  {title:"开胶",choose:false },
  {title:"发黄",choose:false },
  {title:"发白",choose:false }, 
  {title:"划痕",choose:false },
   {title:"棉成块",choose:false}
]

//自营和非自营选择
export const selfOperatedList = [
  {code:1,label:"自营" },
   {code:0,label:"非自营" }
 
]

//自营和非自营选择
export const selfOperatedMap = {
  0:"非自营",
  1:"自营"
 
}